     <!DOCTYPE html>  
<html xmlns="http://www.w3.org/1999/xhtml"  
      xmlns:th="http://www.thymeleaf.org"
      xmlns:sec="http://www.thymeleaf.org/thymeleaf-extras-springsecurity4"">
    <meta name="viewport" content="width=device-width, initial-scale=1.0"/>
    <link rel="stylesheet" href="@{/resources/bootstrap-table-master/assets/bootstrap/css/bootstrap.min.css}"/>
    <link rel="stylesheet" href="@{/resources/bootstrap-table-master/src/bootstrap-table.css}"/>
    <link rel="stylesheet" th:href="@{/resources/bootstrap-table-master/assets/bootstrap/css/bootstrap-treeview.css}"/>
    <script type="text/javascript" th:src="@{/resources/bootstrap-table-master/assets/bootstrap/js/bootstrap-treeview.js}"></script>  
    
    
 <body>       
 	<div class="modal-dialog">
	<div class="modal-content">
    <div class="modal-body">
<form class="form-horizontal" method="post" name="tblTaskEditForm" id="tblTaskEditForm" role="form">
	<input type="hidden" name="seqid" th:value="${sysRole.seqid }"/>
		  <div class="form-group">
    		<label for="name">名称</label>
    		<input type="text" class="form-control" id="name" name="name"  placeholder="请输入名称" th:value="${sysRole.name }"/>
  		</div>
  		  <div class="form-group">
    		<div id="tree"></div>
  		</div>
		  <input type="button" class="btn btn-default" id="sub" value="提交" />
		  <button type="button" class="btn btn-default" data-dismiss="modal">关闭</button>
		  </form>
			</div>
		</div><!-- /.modal-content -->
		</div><!-- /.modal -->

		<script type="text/javascript">
		
		$(document).ready(function() {
				$('#sub').click(function(){
			        $.post('sysRole_save.json',$('#tblTaskEditForm').serialize(),function(result){
			        	$('#table').bootstrapTable('refresh');  
					  	$('#myModal').modal('hide');
					});
			});
			
			 $('#myModal').on('hidden.bs.modal', function () {$(this).removeData()});
			
		}

		//初始化树形结构列表
		   $('#tree').treeview({
		    data: getTree()
		   });
		
		//获取树形结构列表数据
		   function getTree() {
		    var tree = [{
		     text: "Parent 1",
		     nodes: [{
		      text: "Child 1",
		      nodes: [{
		       text: "Grandchild 1"
		      }, {
		       text: "Grandchild 2"
		      }]
		     }, {
		      text: "Child 2"
		     }]
		    }, {
		     text: "Parent 2"
		    }, {
		     text: "Parent 3"
		    }, {
		     text: "Parent 4"
		    }, {
		     text: "Parent 5"
		    }];
		    return tree;
		   }
   
</script>
			
			
				</body>
	</html>